<% @batch.donations.group_by(&:fund_id).each do |f,d| %>
	<div>
		<strong>Fund: <%= Fund.find(f).name %></strong><hr>
		<% d.each do |g| %>
			<div style="margin-left:.5em;">
				<%= number_to_currency g.amount %>
			</div>
		<% end %>
		<strong style="float:right;">Fund Total: <%= number_to_currency d.compact.collect {|h| h.amount rescue nil}.compact.sum rescue nil %></strong><br>
	</div>
<% end %>


<div>
	<strong>Batch Total: <%= number_to_currency @batch.donations.sum(:amount) %></strong>
</div>